<template>
  <view class="container" >
    <up-navbar
        :autoBack="false"
        :placeholder="false"
        leftIcon=""
        title=""
        bgColor="transparent"
        zIndex="999999"

    >
      <template #right>
        <view class="l_f_r_c_c navBar">
          <view class="icon_bg l_f_r_c_c">
          <image @click="saomatwo" class="img" src="https://pili-vod.guanxikeji.com/fubao/img/1755830292510.png" ></image>

          </view>
          <view class="icon_bg l_f_r_c_c">
            <image @click="$goURl(`/pages/index/search`)" class="img" src="https://pili-vod.guanxikeji.com/fubao/img/1755830299478.png" ></image>
          </view>

        </view>

      </template>

    </up-navbar>
    <view>
      <view>
        <!-- 导航栏组件 -->

        <!-- 轮播图 -->
        <view v-if="swiperList.length">
          <!-- <newTop :banners="item"></newTop> -->
          <bgSwiper :showSwiper="true" :list="swiperList" topPadding="0"></bgSwiper>
          <!-- <carousel :data="item"></carousel> -->
        </view>
        <view   class="bottom_msg bg_set l_f_r_sb_c l_al_c" @click="$goURl('/pages/index/notice')" :class="{
          showGG:!showGG
        }" >
          <view class="l_f_r">
            <image  src="https://img.fubaozx.cn/static/newImg/img_03.png" class="img" style="margin-left: 22rpx;"></image>
            <view class="">{{ noticeData[0] && noticeData[0].title || '暂无公告' }}</view>

          </view>
          <up-icon name="arrow-right" size="16" color="#000"></up-icon>
        </view>
        <view class="p_btn l_f_r_c_c">
          <image class="img" @click="setScroll"
                 src="https://pili-vod.guanxikeji.com/fubao/img/1755253004298.png"></image>
        </view>
        <view class="lis_bg bg_set">
          <!--          热销推荐-->
          <view class="item_cnt" v-if="RecommendGoodList.length>0">
           <!-- <view class=" text_5_32 l_f_r_c_c">
              <view class="title_t">
                <view class="left"></view>
                热销推荐
                <view class="right"></view>
              </view>
            </view> -->

						<view class="title-new">
							<view class="n-left">
								<image class="img-icon" src="https://img.fubaozx.cn/static/newImg/img_02.png" mode="widthFix"></image>
								<image class="img-text" src="https://img.fubaozx.cn/static/newImg/img_01.png" mode="widthFix"></image>
							</view>
							<view class="n-right" @click="$goURl('/pages/sellWellList/sellWellList')">
								查看更多
								 <up-icon name="arrow-right" size="16" color="#000"></up-icon>
							</view>
						</view>

            <view class="list_cnt l_f_r">
              <view class="list" style="display: flex;">
                <view class="item l_f_c_c_c " v-for="(item,index) in RecommendGoodList"
                      @click="gogoodsdetail(item.ID)">
                  <view class="img_cnt">
                    <image :src="item.img" mode="aspectFit" class="img"></image>
                  </view>
                  <view class="text_c_r">
                    <text>
                      {{ item.name }}
                    </text>
                  </view>
                  <view class="text-color-n text_c_r">￥{{ item.price }}</view>
                </view>
              </view>
              <!-- <view class="list list2">
                <view class="item " v-for="(item,index) in RecommendGoodListMap.right" @click="gogoodsdetail(item.ID)">
                  <view class="img_cnt">
                    <image :src="item.img" mode="aspectFit" class="img"></image>
                  </view>
                  <view class="text_c_r">
                    <text>
                      {{ item.name }}
                    </text>
                  </view>
                  <view class="price text_c_r">￥{{ item.price }}</view>
                </view>
              </view> -->
            </view>
         <!--   <view class="look_btn text_c_r bg_set" @click="$goURl('/pages/sellWellList/sellWellList')">
            </view> -->
          </view>


          <!--推荐-->
          <view class="img_cnt_box l_f_r_sa_c" >
            <template v-for="(item,index) in carouselList" :key='index'>
              <view class="item bg_set l_f_c" v-if="index<=1" @click="gotoPage(item.url)">
								<image class="item" :src="item.img" mode="aspectFill"></image>
               <!-- <view class="title l_f_r l_al_c">
                  <view class="text_5_32">
                    {{ index == 0 ? '排行榜' : '品牌直销' }}
                  </view>
                  <view v-if="index===0" class="l_f_r_c_c hot-text">热销TOP榜</view>
                  <view v-if="index===1" class="l_f_r_c_c hot-text2">
                    <image src="https://pili-vod.guanxikeji.com/fubao/img/1755243519351.png" class="img"></image>
                    爆品好价
                  </view>
                </view>
                <view class="img_cnt">
                  <image :src="item" mode="aspectFill" class="img"></image>
                </view> -->
              </view>
            </template>

          </view>
          <!-- 普通商品列表 -->
          <view class="item_cnt" v-if="goodsList" style="padding-top: 0;">
            <!-- <view class=" text_5_32 l_f_r_c_c">
              <view class="title_t">
                <view class="left"></view>
                更多商品
                <view class="right"></view>
              </view>
            </view> -->
            <view class=" ">
              <GoodsList v-if="isShow" :goodData="goodsList" :type="2" :isIndex="false"
                         :goodlistData="goodsList"></GoodsList>
            </view>
            <view style="height: 150rpx"></view>
          </view>

        </view>
      </view>
    </view>

    <view class="popUpWindow" v-if="!popUpWindow  && explain.length>0 && explain[0].popUpWindow">
      <view class="box">
        <uni-icons type="closeempty" class="closeempty" color="#fff" size="30"
                   @click="setPopUpWindow"></uni-icons>
        <image :src="explain[0].popUpWindow" mode="widthFix"></image>
      </view>
    </view>
    <uni-popup ref="saomaref" type="bottom" z-index="999999" border-radius="10px 10px 0 0">
      <view class="smbox">


        <view class="cen1" @click="saomatwo()">扫码</view>
        <view class="cen2" @click="imgUp()">相册</view>
      </view>

    </uni-popup>
  </view>
</template>

<script setup>
// import * as qrcode from "@/static/js/reqrcode.js"

import GoodsList from "@/components/home/goods/goodsList.vue"
import bgSwiper from "@/components/home/bg-swiper/bg-swiper.vue"
// import jzH5ScanCode from '@/uni_modules/jz-h5-scanCode/js/index.js'

import {getCurrentInstance, reactive, ref} from "vue";
import {onLoad, onPullDownRefresh, onReachBottom, onShow,onPageScroll} from "@dcloudio/uni-app";
import {useStore} from 'vuex';
const showGG=ref(true)
onPageScroll((e)=>{
  if(e.scrollTop>100){
    showGG.value=false
  }else{
    showGG.value=true
  }
})
const {
  appContext,
  proxy
} = getCurrentInstance();
const saoMa = () => {
  // 允许从相机和相册扫码

  uni.scanCode({
    success: function (res) {
      console.log('条码类型：' + res.scanType);
      console.log('条码内容：' + res.result);
    }
  });

}
// 页面加载时获取屏幕高度
const screenHeight = ref(0)
const noticeData = ref([])
const swiperList = ref([])
const carouselList = ref([])
function getNoticeData() {
  appContext.config.globalProperties.$request({
    url: `api/index/`,
    method: 'GET',
    success(res) {
      if (res.errno == 0) {
        noticeData.value = res.data.notice
        swiperList.value = res.data.carousel

      }
    }
  })
}

onLoad(() => {
  uni.getSystemInfo({
    success: (res) => {
      screenHeight.value = res.windowHeight + 20;
    }
  });
  noticeData.value = uni.getStorageSync('noticeData')
  getGoodsList()
	getCarouselSet()
})
const setScroll = () => {
  uni.pageScrollTo({
    scrollTop: screenHeight.value,
    duration: 200
  });

}
const gotoPage = (url) => {
	if(!url) return
  proxy.$goURl(url)
}

const store = useStore();
const decorationData = store.state.decorationData
let explain = ref([]) //页面所有数据



const bgcolor = ref() //页面背景颜色
const bgimg = ref() //页面背景
const bgheight = ref() //页面背景daxiao
const RecommendGoodList = ref([]) //推荐商品
const RecommendGoodListMap = computed(() => {
  const left = []
  const right = []
  RecommendGoodList.value.forEach((item, index) => {
    if (index % 2 == 0) {
      left.push(item)
    } else {
      right.push(item)
    }
  })
  return {
    left,
    right
  }
})
const isShow = ref(false)
const popUpWindow = ref(false)
let share = ref() //砍价分享
let sharese = ref() //拼团分享
let images = reactive({
  partition: [],
  list: []
})
let goodbargaining = ref({
  user: {
    head: 'https://pili-vod.guanxikeji.com/template/img/1709602500291.png',
    nickname: '测试',
    mobile: '13048448888',

  },
  goods: {
    img: 'https://pili-vod.guanxikeji.com/template/img/1709602500291.png',
    name: '测试',
  },
  ID: 0
})
let goodLists = ref({
  goods: {
    img: 'https://pili-vod.guanxikeji.com/template/img/1709602500291.png',
    name: '测试',
  }
})
let goodListse = ref({
  head: 'https://pili-vod.guanxikeji.com/template/img/1709602500291.png',
  nickname: 'https://pili-vod.guanxikeji.com/template/img/1709602500291.png',
  mobile: '13048448888',
})
let arrse = ref([])
const data = reactive({
  page: 0,
  size: 20,
  pages: 1,
  goodlistData: [], // 推荐商品
  navBarTitle: "这是一个导航",
  pageBgColor: "$green",
  // 轮播数据
  swiperList: [{
    colorClass: 'uni-bg-red',
    url: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
    content: '内容 A'
  }, {
    colorClass: 'uni-bg-green',
    url: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
    content: '内容 B'
  }, {
    colorClass: 'uni-bg-blue',
    url: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
    content: '内容 C'
  }],
  // 指示点数据
  dotStyle: {
    backgroundColor: 'rgba(0, 0, 0, .3)',
    border: '1px rgba(0, 0, 0, .3) solid',
    color: '#fff',
    selectedBackgroundColor: 'rgba(0, 0, 0, .9)',
    selectedBorder: '1px rgba(0, 0, 0, .9) solid'
  },
  current: 0,
  mode: 'round',
  swiperDotIndex: 0,
  // 公告
  notice: [{
    content: "这是一段公告1"
  }],
  // 功能导航
  navigation: [
    [{
      img: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
      name: '内容 B'
    }, {
      img: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
      name: '内容 B'
    }, {
      img: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
      name: '内容 B'
    }, {
      img: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
      name: '内容 B'
    }]
  ],
  list: [{
    name: '10:11',
    list: [],
    subheading: '即将开始'
  }, {
    name: '12:11',
    list: [],
    subheading: '即将开始'
  }],

})
const gogoodsdetail = (id) => {
  uni.navigateTo({
    url: '/subPackages/commodity/details?id=' + id
  })
}
onLoad((option) => {
  data.page = 0
  data.pages = 1

  data.goodlistData = []
  getIndex()
  getPartition()
  getRecommendGoods()
  getNoticeData()
})
onShow(() => {
  uni.getClipboardData({
    success: function (res) {

      uni.hideLoading()
      if (res.data.indexOf('砍价') != -1) {
        let str = res.data.substring(res.data.length - (res.data.length - 29))
        bargaining(str.slice(1, str.length - 2))

      } else if (res.data.indexOf('拼团') != -1) {
        let str = res.data.substring(res.data.length - (res.data.length - 29))
        bargainingse(str.slice(1, str.length - 2))
      }
    },
    fail: function (err) {
      // console.log(err, )
    }
  });
  try {
    popUpWindow.value = uni.getStorageSync("popUpWindow") || false
  } catch (e) {

    popUpWindow.value = false
    //TODO handle the exception
  }

})
onPullDownRefresh(() => {
  setTimeout(() => {
    uni.stopPullDownRefresh();
  }, 1000);
})
//下拉刷新
onReachBottom(() => {
  getGoodData()
})

function getCarouselSet() {
	appContext.config.globalProperties.$request({
	  url: `api/carouselList/?code=3`,
	  method: 'get',
	  success(res) {
	    carouselList.value = res.data.data

	  }
	})
}

//拼团
function bargainingse(id) {
  appContext.config.globalProperties.$request({
    url: `api/teamwork/joiningGroups/${id}/`,
    method: 'post',
    success(res) {
      if (res.errno == 0) {
        let userlist = res.data.userList
        console.log(uni.getStorageSync('userInfo').mobile, "mobileid")
        console.log(userlist, "userlist")
        userlist.forEach((items) => {
          if (items.mobile == uni.getStorageSync('userInfo').mobile) {
            arrse.value.push(items)
          }


        })
        console.log(arrse, "arrse")
        if (arrse.value.length == 0) {
          goodLists.value = res.data.data
          goodListse.value = res.data.userList[0]
          sharese.value.open()
        } else {
          uni.showToast({
            icon: 'none',
            title: '参加过了哦！'
          })
        }
      }

    }
  })
}

//砍价
function bargaining(id) {
  console.log(id, parseInt(id), " Number(id)")
  appContext.config.globalProperties.$request({
    url: `api/bargaining/bargainingList/`,
    method: 'post',
    data: {
      id: Number(id)
    },
    success(res) {
      if (res.errno == 0 && res.data.user.mobile != uni.getStorageSync('userInfo').mobile) {
        goodbargaining.value = res.data
        share.value.open()
      }
    }
  })
}

function setId(id) { //截取后4位
  try {
    return id.substring(id.length - 4)
  } catch (e) {
    return '****'
  }
}

function goURlee(item) {
  uni.navigateTo({
    url: '/subPackages/commodity/bargaining/myGroupBuyinglist/createorderGroupCY'
  })
  share.value.close()
  uni.setStorageSync('goodlist', item)
  uni.setClipboardData({
    data: '',
    success: function () {
      console.log('success');
    }
  });
}

function goURle(urls) {
  uni.navigateTo({
    url: urls
  })
  share.value.close()
  uni.setClipboardData({
    data: '',
    success: function () {
      console.log('success');
    }
  });
}

function setPopUpWindow() {
  popUpWindow.value = true
  uni.setStorageSync("popUpWindow", true)
}

function shopClassList() {
  proxy.$request({
    url: `api/shopClassList/?page=1&size=999`,
    method: 'get',
    success(res) {
    }
  })
}

//获取首页格式
function getIndex() {

  proxy.$request({
    url: `api/decoration/`,
    method: 'get',
    success(res) {
      if (res.errno == 0 && res.data.explain != '') {
        explain.value = JSON.parse(res.data.explain)
        explain.value.forEach((it) => {
          if (it.type == 'info') {
            bgcolor.value = it.backgroundColor
            bgimg.value = it.backgroundImage
            bgheight.value = it.height
          }
          if (typeof it.tabType == 'string') {
            it.tabType = parseInt(it.tabType);
          }
        })

        console.log('explain', explain)

      }
    }
  })
  getGoodData()
}

function getGoodData() {
  if (data.page < data.pages) {
    data.page++
    appContext.config.globalProperties.$request({
      url: `api/goods_list_all/0/?page=${data.page}&size=${data.size}&is_index=1&is_single=0`,
      method: 'get',
      success(resd) {
        if (resd.errno == 0) {
          data.pages = Math.ceil(resd.data.total / data.size)
          data.goodlistData = resd.data.data
          isShow.value = true
          console.log('goodlistData', data.goodlistData)
        }
      }
    })
  }
}
const goodsQuery = ref({
  page: 1,
  size: 20,
})
const goodsList = ref([])
const goodsTotal = ref(0)
const getGoodsList=() => {
  if ((goodsQuery.value.page-1)*goodsQuery.value.size >= goodsTotal.value&&goodsTotal.value!=0) {
    return
  }
    appContext.config.globalProperties.$request({
      url: `api/goods_list_all/0/?page=${goodsQuery.value.page}&size=${goodsQuery.value.size}`,
      method: 'get',
      success(res) {
        if (res.errno == 0) {
          const list=res.data.data
          goodsList.value = [...goodsList.value,...list]
          goodsTotal.value = res.data.total
          goodsQuery.value.page++
        }
      }
    })
}
onReachBottom(()=>{
  console.log(555)
  getGoodsList()
})

// 推荐商品
const getRecommendGoods = () => {
  appContext.config.globalProperties.$request({
    url: `api/goods_list_all/0/?page=1&size=3&is_hot=1&sort=1`,
    method: 'get',
    success(resd) {
      if (resd.errno == 0) {
        RecommendGoodList.value = resd.data.data
      }
    }
  })
}

//获取分区
function getPartition() {
  appContext.config.globalProperties.$request({
    url: `api/partition/?page=1&size=999`,
    method: 'get',
    success(res) {
      if (res.errno == 0) {
        console.log("partition", res.data.data)
        images.partition = res.data.data
        getRewardGoods()
      }
    }
  })
}

//获取报单区商品
function getRewardGoods() {
  appContext.config.globalProperties.$request({
    url: `api/goods_list_all/0/?page=1&size=999&is_index=1&is_single=1`,
    method: 'get',
    success(res) {
      if (res.errno == 0) {
        console.log("goods_list_all", res.data.data)
        images.list = res.data.data
      }
    }
  })
}

let saomaref = ref()

function saoma() {
  saomaref.value.open()
  // #ifdef H5
  // if (origin.indexOf('https') === -1) {
  // 	imgUp()
  // } else {
  // 	uni.navigateTo({
  // 		url: '/pages/ScanCode/ScanCode'
  // 	})
  // }
  // #endif

}

function saomatwo() {
  saomaref.value.close()

  // #ifdef H5
  // uni.navigateTo({
  //   url: '/pages/ScanCode/ScanCode'
  // })
  // 基础扫码
  // jzH5ScanCode.scanCode({
  //   success: (res) => {
  //     console.log('扫码成功:', res.result)
  //     const url=res.result.split('?')[1]
  //     // pages/business/pay
  //     uni.navigateTo({
  //       url:`/subPackages/business/pay?${url}`
  //     })
  //   },
  //   fail: (res) => {
  //     console.log('扫码失败:', res.errMsg)
  //     uni.showToast({
  //       icon: 'none',
  //       title: '扫码失败'
  //     })
  //   }
  // })
  // #endif


  // #ifndef H5
  uni.scanCode({
    success: function (res) {
     //  条码类型：QR_CODE
     // 条码内容：http://192.168.2.66:5173/h5/#/subPackages/personal/wallet/payment?id=1&logo=https://img.shengshantaling.com/hemajishi/17555051861134.png&name=测试&title=北京市市辖区东城区测试

          console.log('条码类型：' + res.scanType);
      console.log('条码内容：' + res.result);
      const url=res.result.split('?')[1]
      // pages/business/pay
      uni.navigateTo({
        url:`/subPackages/business/pay?${url}`
      })
    }
  });
  // #endif
}

// function imgUp() {
//   saomaref.value.close()
//   uni.chooseImage({
//     sizeType: ['original'],
//     sourceType: ['album'], //从相册选择
//     count: 1,
//     success: function(res) {
//       console.log(res, "res")
//       const tempFilePaths = res.tempFilePaths
//       qrcode.qrcode.decode(tempFilePaths[0]);
//       qrcode.qrcode.callback = function(img) {
//         console.log(img, "imgimg")
//         if (img == "error decoding QR Code") {
//           uni.showToast({
//             title: "识别二维码失败，请重新上传！",
//             duration: 2000,
//             icon: 'none'
//           })
//         } else {
//           console.log('img', img)
//           let user = uni.getStorageSync('userInfo')
//           if (user.uid) {
//             let str = img.split('?')[1]
//             uni.navigateTo({
//               url:`/subPackages/business/pay?${str}`
//
//             })
//           } else {
//             let str = img.split('#')[1]
//             uni.setStorageSync('paymenturl', str)
//             uni.navigateTo({
//               url: img
//             })
//           }
//           // let dats = img.split('=')
//           // appContext.config.globalProperties.$goURl('/subPackages/business/pay?id=' + dats[0] + '&discount=' + dats[
//           // 	1] + '&notes=' + dats[2] + '&money=' + dats[3])
//         }
//       }
//     }
//   });
// }
</script>

<style lang="scss" scoped>
.container {
  // position: relative;
  min-height: calc(100vh - 50px);
  background-size: 100% 100%;
  background-repeat: no-repeat;

  // 头部背景颜色
  .headerBgColor {
    position: absolute;
    left: 0;
    top: 0;
    width: 100vw;
    background-color: #00C356;
    height: 220px;
  }

  // 头部
  .header {
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #00C356;
    padding: 0 30upx;

    .left {
      font-size: 13px;
      font-weight: bold;
      color: #fff;
      z-index: 99;
    }

    .rightSearch {
      width: calc(100% - 160upx);
    }
  }

  uni-swiper {
    height: auto;
  }

  // 轮播
  .swiperdotbox {
    margin: 30upx;

    .swiper-box {
      .swiperImage {
        width: 100%;
        height: 100%;
        border-radius: 30upx;
      }
    }
  }


}

.popUpWindow {
  position: fixed;
  width: 100vw;
  height: 100vh;
  z-index: 999;
  top: 0;
  left: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;

  .box {
    width: 80vw;
    position: relative;

    .closeempty {
      // position: absolute;
      // right: 0;
      // top: -10px;
      // z-index: 9999;
      display: flex;
      justify-content: center;
      margin-bottom: 20rpx;
    }

    image {
      width: 100%;
    }
  }
}

::v-deep .uni-noticebar {
  margin: 0;
}

.lis_bg {
  width: 750rpx;
  // background-image: url("https://pili-vod.guanxikeji.com/fubao/img/1755237926852.png");
	background: linear-gradient( 180deg, #FFFFFF 0%, #F7F7F7 100%);
  background-repeat: repeat;
  min-height: 3304rpx;
  border-radius: 0rpx 0rpx 0rpx 0rpx;
  padding-top: 1rpx;

  .item_cnt {
    padding-top: 64rpx;

    .title_t {
      position: relative;
      color: #834E19;

      .right, .left {
        position: absolute;
        top: 50%;
        left: -86rpx;
        transform: translateY(-50%);
        width: 76rpx;
        height: 2rpx;
        background-image: linear-gradient(90deg, rgba(247, 242, 237, 0), rgba(131, 78, 25, 1));
      }

      .right {
        left: auto;
        right: -86rpx;
        background-image: linear-gradient(270deg, rgba(247, 242, 237, 0), rgba(131, 78, 25, 1));
      }


    }

    .list_cnt {

			padding: 0;
			margin: 0 30rpx;
      .list {

				width: 100%;
				display: flex;
				justify-content: space-between;

        .item {
          width: 220rpx;
          height: 320rpx;
          background: rgba(217, 217, 217, 0);
					background: #FFEFE9;
					border-radius: 12rpx;
          .img {
            width: 192rpx;
            height: 192rpx;
						border-radius: 16rpx;
          }

          .text_c_r {
						margin: 0 20rpx;
            text-align: center;
						display: -webkit-box;
						-webkit-line-clamp: 1;
						-webkit-box-orient: vertical;
						overflow: hidden;
						color: #000;
						font-size: 26rpx;
          }
					.text-color-n{
						font-size: 30rpx;
						color: #ED1619;
						margin-top: 10rpx;
					}
        }

      }

      .list2 {
        //margin-top: 106rpx;
      }
    }

    .look_btn {
      width: 216rpx;
      height: 60rpx;
      margin: 20rpx auto;
      background-image: url("https://pili-vod.guanxikeji.com/fubao/img/1755241268030.png");
    }
  }

  .img_cnt_box {
    margin-top: 40rpx;
    padding: 0 20rpx;

    .item {
      width: 336rpx;
      height: 244rpx;


      .title {
        padding: 20rpx;

        .hot-text {
          font-family: PingFang SC, PingFang SC;
          font-weight: 300;
          font-size: 22rpx;
          color: #000000;
          line-height: 32rpx;
          margin-left: 12rpx;

          width: 128rpx;
          height: 32rpx;
          background: #FFDCB9;
          border-radius: 0rpx 0rpx 0rpx 0rpx;
        }

        .hot-text2 {
          font-family: PingFang SC, PingFang SC;
          font-weight: 400;
          font-size: 22rpx;
          color: #2E7D32;
          line-height: 32rpx;
          width: 128rpx;
          height: 32rpx;
          background: #FFDDBC;
          border-radius: 0rpx 0rpx 0rpx 0rpx;

          .img {
            width: 16rpx;
            height: 21rpx;
            margin-right: 8rpx;
          }
        }

      }

      .img_cnt {
        width: 100%;
        flex: 1;
      }
    }


  }
}

.bottom_msg {
  position: absolute;
	height: 78rpx;
	background: #FFFFFF;
	border-radius: 39rpx;
	bottom: 22rpx;
	padding-right: 20rpx;
  left: 30rpx;
	right: 30rpx;
	color: #000;
	font-size: 24rpx;
  box-sizing: border-box;
  z-index: 99;
  margin-top: -94rpx;
  transition: all 0.5s;
  &.showGG{
    opacity: 0;
    pointer-events: none;
  }


  .img {
    width: 36rpx;
    height: 36rpx;
    margin-right: 20rpx;
  }
}

.navBar {
  gap: 20rpx;

  .img {
    height: 52rpx;
    width: 52rpx;
    z-index: 9;
  }
  //.icon_bg{
  //  width: 50rpx;
  //  height: 50rpx;
  //  //border-radius: 50%;
  //  border-radius: 10rpx;
  //  //background-color: rgba(0, 0, 0, 0.3);
  //}
}

.p_btn {
  position: absolute;
  z-index: 9998;

  width: 100vw;
  top: 75vh;

  .img {
    width: 96rpx;
    height: 96rpx;
  }
}
	.smbox {
  background-color: #fff;
  padding: 50rpx 0rpx;
  border-radius: 10rpx;
  width: 100%;
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
  font-size: 28rpx;
  font-weight: bold;
  //margin-bottom: 100rpx;

  .cen1 {
    width: 90%;
    display: flex;
    justify-content: center;
    padding-bottom: 30rpx;
    border-bottom: 1px solid #ccc;
  }

  .cen2 {
    width: 90%;
    display: flex;
    justify-content: center;
    padding-top: 20rpx;

  }
}
  :deep(.uni-popup ){
    z-index: 9999;
  }
  :deep(.u-navbar--fixed){
    z-index: 9998;

  }
.title-new{
	display: flex;
	align-items: center;
	justify-content: space-between;
	font-weight: 500;
	font-size: 26rpx;
	color: #2D2D2D;
	margin: 0 30rpx;
	.n-left{
		display: flex;
		align-items: center;
		.img-icon{
			width: 80rpx;
			margin-right: 6rpx;
		}
		.img-text{
			width: 126rpx;
		}
	}
	.n-right{
		display: flex;
		align-items: center;
	}
}
</style>
